#!/usr/bin/node 

const fs = require('fs');
const log = console.log;
var w = fs.watch(__dirname, log);

process.on('SIGINT', () => {
  w.close();
  console.log('程序并不立即结束，需要等 5 秒后才结束');

  setTimeout(() => {
    process.exit();
  }, 5000);
});
